package com.example.jasonrpc.example;

public class StringServiceImpl implements StringService{
    @Override
    public String greeting(String hello) {
        if ("Hello".equals(hello)) {
            return "world";
        }else if ("ping".equals(hello)) {
            return "pong";
        }else if ("天王盖地虎".equals(hello)) {
            return "小鸡炖蘑菇";
        }
        throw new IllegalStateException("暗号错误！");
    }
}
